<template>
  <!-- <el-dialog
    :title="title"
    :width="1200"
    :visible="visible"
     fullscreen
     switchFullscreen
    @cancel="handleCancel"
    cancelText="关闭">

  </el-dialog> -->
  <div class="pdfPriview">
    <iframe
      :src="pdfUrl"
      width="100%"
      frameborder="0"
      scrolling="auto"
      height="100vh"
    />
  </div>
</template>

<script>

export default {
  name: 'Word',
  components: {

  },
  data() {
    return {
      title: '操作',
      visible: false,
      pdfUrl: ''
    }
  },
  created() {
  },
  mounted() {
    this.pdfUrl = 'https://view.officeapps.live.com/op/embed.aspx?src=' + this.$route.query.url
  },
  methods: {
    show(url) {
      this.pdfUrl = ''
      this.visible = true
      this.pdfUrl = 'https://view.officeapps.live.com/op/embed.aspx?src=' + url
    },
    close() {
      this.$emit('close')
      this.visible = false
    },
    handleCancel() {
      this.close()
    }
  }
}
</script>

<style lang="scss" scoped>
  .ant-input {
    resize: none;
  }
  iframe{
    height: 100vh;
    overflow: auto;
  }
</style>
